﻿using System;
using System.Collections.Generic;
using System.Data;


namespace Pub.DBUtility
{
    /// <summary>
    /// 数据访问接口 by chunhua.guo
    /// </summary>
    public interface IDataBaseService
    {

        void m_mthCreateDB(string DBName);

        void m_mthChagePassword();
        int ExecuteSqlTran(List<string> SQLStringList);
        void CreateParameters(int num, out IDataParameter[] param);
        /// <summary>
        /// 获取数据
        /// </summary>
        /// <param name="strSQL"></param>
        /// <param name="dtResult"></param>
        /// <param name="Params"></param>
        /// <returns></returns>
        long GetTableWithParams(String strSQL, ref DataTable dtResult, params IDataParameter[] Params);
        /// <summary>
        /// 执行有参数
        /// </summary>
        /// <param name="strSQL"></param>
        /// <param name="AffectedCount"></param>
        /// <param name="Params"></param>
        /// <returns></returns>
        long ExecParamSQL(String strSQL, ref long AffectedCount, params IDataParameter[] Params);
        /// <summary>
        /// 有参数存储过程
        /// </summary>
        /// <param name="strSQL"></param>
        /// <param name="strConnect"></param>
        /// <param name="Params"></param>
        /// <returns></returns>
        long ExecParamProc(String strSQL, params IDataParameter[] Params);

        long GetTableFromProc(string strProcName, ref DataTable dtResult);

    }
}
